package com.shuke.medical.insure.controller;

import com.shuke.medical.insure.model.bo.ChsMdRegister;
import com.shuke.medical.insure.model.bo.ChsMdVisitUpload;
import com.shuke.medical.insure.model.bo.ChsSignOutBO;
import com.shuke.medical.insure.service.ChsMdService;
import com.shuke.medical.insure.utils.R;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/***
 * @title ChsMdController
 * @description： 门诊业务管理
 * @author woo hua
 * @version 1.0.0
 * @create 2023/4/4 10:46
 **/
@Slf4j
@RestController
@RequestMapping("/chsMd")
public class ChsMdController {

    @Resource
    private ChsMdService chsMdService;

    @PostMapping("/do2201")
    public R<ChsMdRegister.Output> do2201(@RequestBody ChsMdRegister chsMdRegister) throws Exception {
        return R.ok(chsMdService.do2201(chsMdRegister));
    }

    @PostMapping("/do2203")
    public R<Void> do2203(@RequestBody ChsMdVisitUpload visitUpload) throws Exception {
        chsMdService.do2203(visitUpload);
        return R.ok();
    }

    @PostMapping("/do9002")
    public R<Void> do9002(@RequestBody ChsSignOutBO.Input input) throws Exception {
        chsMdService.do9002(input);
        return R.ok();
    }
}
